﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace doubanloginDll8
{
    /// <summary>
    /// 播放的历史列表，用于长报告
    /// </summary>
    public class DoubanPlayedList
    {
        /// <summary>
        /// 已经播放的列表
        /// </summary>
        private List<DoubanPlayedSong> playedSongs = new List<DoubanPlayedSong>();

        /// <summary>
        /// 已经播放的列表
        /// </summary>
        public List<DoubanPlayedSong> PlayedSongs
        {
            get { return playedSongs; }
            set { playedSongs = value; }
        }

        public void add(DoubanPlayedSong song)
        {
            if (this.playedSongs.Count > 30)
            {
                this.playedSongs.RemoveAt(0);
            }
            this.playedSongs.Add(song);
        }
    }
}
